//
// Created by HP on 2022/2/2.
//

#ifndef TMC_MOVEMENT_CONTROLLER_H
#define TMC_MOVEMENT_CONTROLLER_H

#include "tmc_game_object.h"
#include "tmc_window.h"

namespace tmc {
    class MovementController {
    public:
        struct KeyMappings {
            int moveLeft = GLFW_KEY_A;
            int moveRight = GLFW_KEY_D;
            int moveForward = GLFW_KEY_W;
            int moveBackward = GLFW_KEY_S;
        };

        void moveInPlaneXZ(GLFWwindow* window, float dt, TmcGameObject& gameObject);

        KeyMappings keys{};
        glm::vec2 cursor{0.f, 0.f};
        float moveSpeed{3.f};
        float lookSpeed{1.5f};
    };
}

#endif //TMC_MOVEMENT_CONTROLLER_H
